<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
		<title>Trombino</title>
	</head>
	
	<body>
	<table align="center" border="1" width="1080">
		<tr>
			<td align="center"><c:import url="../template/header.jsp" /></td>
		</tr>
		<tr>
			<td align="center">
				<table border="1">
					<c:forEach var="album" items="${albumList}">
					<tr>
						<td align="left" bgcolor="799AE1">Album > ${album.getTitle()} </td>
					</tr>
					<tr>
						<td>
							<table border="1"> 
								<tr>
									<c:set var="i" value="${0}"/>
									<c:forEach var="photo" items="${album.getPhotoList()}">										
										<c:if test="${i % 4 == 0}">
											</tr><tr>
										</c:if>
										<td><a href="<c:url value='/photo/detail/${photo.getIdNum()}'/>">
											<img src="${photo.getUrl()}" width="256" height="192"/>
											</a>
										</td>
										<c:set var="i" value="${i+1}"/>
									</c:forEach>
								</tr>
							</table>				
						</td>
					</tr>
					</c:forEach>
				</table>	
			</td>
		</tr>
		<tr>
			<td align="center"><c:import url="../template/footer.jsp" /></td>
		</tr>
	</table>
		
	</body>
</html>